<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/commons/taglibs.jsp" %>
<html>
<head>
	<%@ include file="/commons/meta.jsp" %>
	<link href="${ctx}/widgets/extremecomponents/extremecomponents.css" type="text/css" rel="stylesheet">
	<title>User Manage</title>
</head>

<body>
<div id="page">
	<div id="header">
		<h1>Helloworld Sample</h1>
	</div>

	<div id="content">
		<h1>User List</h1>
		<%@ include file="/commons/messages.jsp" %>
		<ec:table items="users" var="user"
				  action="${ctx}/user.do">
			<ec:exportXls fileName="UserList.xls" tooltip="Export Excel"/>
			<ec:row>
				<ec:column property="rowcount" cell="rowCount" sortable="false" title="No." width="60"/>
				<ec:column property="id" title="ID" width="60"/>
				<ec:column property="name" title="Name" width="120"/>
				<ec:column property="email" title="Email" width="120"/>
				<ec:column property="descn" title="Description" viewsDenied="html"/>
				<ec:column property="null" title="Edit" width="40" sortable="false" viewsAllowed="html">
					<a href="user.do?method=edit&id=${user.id}">Edit</a>
				</ec:column>
				<ec:column property="null" title="Remove" width="40" sortable="false" viewsAllowed="html">
					<a href="user.do?method=delete&id=${user.id}">Delete</a>
				</ec:column>
			</ec:row>
		</ec:table>
	</div>

	<div>
		<button id="addbtn" onclick="location.href='user.do?method=create'">Add</button>
	</div>
</div>
<%@ include file="/commons/footer.jsp" %>
</body>
</html>